#include <iostream>
#include <math.h>
using namespace std;

signed main()
{
	int n;
	cin>>n;
	float Max = 0;
	for(int i=0;i<n;i++){
		int a,b;
		cin>>a>>b;
		float t = sqrt(a*a+b*b);
		Max = t>Max?t:Max;
	}
	printf("%.2f",Max);
	return 0;
} 
